import 'package:flutter/material.dart';

extension ColorEx on Color {
  /// 改变颜色的亮度值，[lightness]取值0.0~1.0
  Color withLightness(double lightness) {
    return HSLColor.fromColor(this).withLightness(lightness).toColor();
  }
}
